<template>
	<view>
		<view class="item" @tap="toRadio(item.songId)" v-for="(item,index) in songlist" :key="item.songId">
			<text class="te">{{index+1}} {{item.songName}}
				<text class="t2">- {{item.singerName}}</text>
			</text>
		</view>
	</view>
</template>

<script>
	import {mapState,mapMutations} from 'vuex'
	export default {
		data() {
			return {
				
			};
		},
		computed:{
			...mapState('song',['songlist']),
			getLength(){
				return this.songlist.length
			}
		},
		methods:{
			toRadio(id){
				uni.navigateTo({
					url:"/pages/mus/mus?songId="+id
				})
			},
		}
	}
</script>

<style lang="scss">
	.item {
		height: 80rpx;
		display: flex;
		justify-items: center;
		margin: 20rpx 40rpx;
		border: 2rpx solid gray;
		border-radius: 20rpx;
		overflow: hidden;
		white-space: nowrap;
		text-overflow: ellipsis;

		.te {
			margin-left: 20rpx;
			line-height: 80rpx;
			font-size: 45rpx;

			.t2 {
				margin-left: 30rpx;
				font-size: 40rpx;
			}
		}
	}
</style>
